@import "mixin_helpers";
@import "variables";

.accordion {
  @include border-radius(4px);
}

.accordion-group {
  margin-bottom: 0;
  border: 1px solid $box-border-color;
  border-bottom: none;
  @include border-radius(0);
  margin-top: -1px;
  border-top: none;

  .accordion-heading {
    @include box-header-aspect;
    border-top: 1px solid $box-border-color;
  }

  &:first-child {
    @include border-top-left-radius(4px);
    @include border-top-right-radius(4px);

    margin-top: 0px;
    border-top: none;
    .accordion-heading {
      @include border-top-left-radius(4px);
      @include border-top-right-radius(4px);
    }
  }

  &:last-child {
    @include border-bottom-left-radius(4px);
    @include border-bottom-right-radius(4px);
    border-bottom: 1px solid $box-border-color;
  }

  .accordion-inner {
    background: $box-background;
    margin-bottom: 1px;
  }
}

.accordion-heading .accordion-toggle {
  padding: 10px;
  color: $box-header-text-color;
}

.accordion-inner {
  .nav {
    margin-bottom: 0;
  }

  .nav li {
    line-height: 40px;
    height: 40px;
    border-bottom: 1px solid #ddd;

    a {
      padding-left: 10px;
    }

    &:last-child {
      border-bottom: none;
    }
  }
}

.sidebar-tabs {
  .accordion {
    @include border-radius(0);

    .active {
      border-left: 6px solid #505050;
      margin-left: -3px;

      a {
        padding-left: 7px;
        color: #505050;
      }
    }
  }

  .accordion-group {
    border-left: none;
    border-right: none;

    &:first-child, &:first-child .accordion-heading, &:last-child {
      @include border-radius(0);
    }

    &:last-child {
      border-bottom: none;
    }
  }

  .accordion-heading .accordion-toggle {
    padding: 15px;
  }

}